<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>预览文档</title>
</head>
<style>
  html,
  body {
    height: 100%;
    width: 100%;
  }

  * {
    margin: 0;
    padding: 0;
  }

  #app {
    width: 100%;
    height: 100%;
    display: flex;
  }

  .common-auto {
    width: 100%;
    height: 100%;
  }

  .html-content {
    width: 100%;
    height: 100%;
    overflow-y: auto;
  }
</style>

<body>
  <div id="app">
    <div class="common-auto">
      <div v-html="content" class="html-content"></div>
    </div>
  </div>
  <script src="./vue.js"></script>

  <script>
    let vm = new Vue({
      el: '#app',
      data() {
        return {
          showHtml: false,
          content: ""
        }
      },

    })

    function findhtml(data) {
      console.log('contentda', data);
      vm._data.content = data;
      vm._data.showHtml = true
    }

  </script>
</body>

</html>